package com.zhouyu.aspect;

import org.aspectj.lang.JoinPoint;
import org.aspectj.lang.annotation.Before;
import org.aspectj.lang.annotation.Pointcut;

//@Aspect
//@Component
public class ZhouyuAspect {

	@Pointcut("execution(public void com.zhouyu.service.UserService.test())")
	public void a()
	{

	}

	@Before("a()")
	public void zhouyuBefore(JoinPoint joinPoint)
	{
		System.out.println("zhouyuBefore");
	}

	@Before(value = "execution(public void com.zhouyu.service.UserService.test2(..)) && args(a,b,c)", argNames = "a,b,c")
	public void testBefore(JoinPoint joinPoint, String a, String b, String c)
	{
		System.out.println(a);
		System.out.println(b);
		System.out.println(c);
	}


}
